package cn.mactoon.controller;


import cn.mactoon.utils.SmsUtils;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/sms")
public class SmsController {
    @Resource
    private SmsUtils smsUtils;

    @PostMapping("/send")
    public boolean send(String to, String templateId, String[] datas){
        to="13339618195";
        templateId="1";
        datas = new String[]{"1236", "1"};
        return smsUtils.SmsSend(to,templateId,datas);
    }
}
